package com.niit.onlinemusic.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.niit.onlinemusic.common.R;
import com.niit.onlinemusic.mapper.SingerMapper;
import com.niit.onlinemusic.model.domain.Singer;
import com.niit.onlinemusic.service.SingerService;
import org.springframework.stereotype.Service;

/**
 * 歌手业务层实现类
 *
 * @author zuwei522
 * @since 2025/9/17 16:19
 */
@Service
public class SingerServiceImpl extends ServiceImpl<SingerMapper, Singer> implements SingerService {

    private final SingerMapper singerMapper;

    public SingerServiceImpl(SingerMapper singerMapper) {
        this.singerMapper = singerMapper;
    }

    @Override
    public R getAllSingers() {
        return R.success("查询成功", singerMapper.selectList(null));
    }
}
